package com.cn.service;

import com.cn.dao.CardMapper;
import com.cn.dao.DealMapper;
import com.cn.entity.Card;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CardService {


    @Autowired
    private CardMapper cardMapper;

    public CardMapper getCardMapper() {
        return cardMapper;
    }

    public void setCardMapper(CardMapper cardMapper) {
        this.cardMapper = cardMapper;
    }

    public void setCard(Card card) {
          cardMapper.setCard(card);

    }
    public Card	getCardByNum(String cardNum){
        return cardMapper.getCardByNum(cardNum);
    }

    public String getAccountByNum(String cardNum) {
        return cardMapper.getAccountByNum(cardNum);

    }

    public Card findCard(Card card) {
        return cardMapper.findCard(card);
    }

    public void unboundCard(Card card) {
      cardMapper.unboundCard(card);
    }
}
